#pragma once
#include "BlueprintScriptLibrary/RegistAction.h"
#include "GraphBase.h"

class GetVarGraph : public GraphBase
{
public:
    GetVarGraph() { graphName = "GetVar"; }
    bool OnInit();
    void InitParaPin();
    virtual void ParseXmlElement(class TiXmlElement* ele);
    bool SetAttribute(const char* attrName, const char* attrVal);
    void OnDraw();

    virtual void onMouseButtonDown(int button, int x, int y);
    void onMouseMove(int x, int y);
    void onMouseButtonUp(int button, int x, int y);
    BlueprintScriptLibrary::Class* GetClass();
    Vec2vbi GetOutputPinPos(int index);
    VarBaseInt GetInputPinNum() { return 0; }
    VarBaseInt GetOuputPinNum() { return 0; }

    void Execute();
    FunctionPin* GetFunctionPin();
    void ConnectTo(GraphBase* graph, int index = 0);
    VarBaseString varName;
    Var* varValue;
    IVariableEntity* ive;
    class OutputParaPin* opp;
};
RegisterBlueprintClass(GetVarGraph)
